package cn.roadtrip.utilmodule.util.enumpck;

/**
 * 领队最终绑定车辆状态
 */
public enum Enum_LeaderBindFinalCarStats {
    //-；-；-
    WaitDispatch("WaitDispatch", "待调度"),
    WaitApply("WaitApply", "待同意"),
    DispatchFinish("DispatchFinish", "调度完成");

    private String s;
    private String title;

    Enum_LeaderBindFinalCarStats(String s, String title) {
        this.s = s;
        this.title = title;
    }

    Enum_LeaderBindFinalCarStats(String s) {
        this.s = s;
        this.title = Enum_HotelRoomType.parseCode(s).getTitle();
    }

    public String getTitle() {
        return this.title;
    }

    public String getCode() {
        return this.s;
    }

    public static final Enum_LeaderBindFinalCarStats parseCode(String code) {
        switch (code) {
            case "WaitDispatch":
                return WaitDispatch;
            case "WaitApply":
                return WaitApply;
            case "DispatchFinish":
                return DispatchFinish;
        }
        return null;
    }

    @Override
    public String toString() {
        return "(code:%s, title:%s)".formatted(this.s, this.title);
    }

}
